#include "student.h"
#include<QDebug>

Student::Student(QObject *parent) : QObject(parent)
{

}
void Student::treat(){
    qDebug()<<"chifan";
}
void Student::treat(QString foodName){

    //QString->char * QString 默认带引号
    //先转成 QByteArray(.toUtf8()) 再转char *()
    qDebug()<<"teacher want to eat:"<<foodName.toUtf8().data();

}
